#include <SDL/SDL.h>
#include <GamingLibraries/Widgets.h>
#include <stdio.h>

int Progress = 0;
int Increase = 1;
int main()
{
	SDL_Init(SDL_INIT_VIDEO);
	SDL_Surface *Screen = SDL_SetVideoMode(700, 800, 24, SDL_DOUBLEBUF|SDL_HWSURFACE);
	W_Init();
	W_Colour Colour = {255, 255, 0};
	//W_Widget *W = W_NewProgressBar(10, 10, 40, 50, 10, Colour);
	W_Widget *W = W_NewLabel(10, 10, 12, S_NewString("Cameron"), "Font.ttf", Colour);
	if(W == NULL)
	{
		printf("Oh noes!\n");
		printf("%s\n", SDL_GetError());
		exit(1);
	}
	while(1)
	{
		SDL_Event E;
		SDL_PollEvent(&E);
		if(E.type == SDL_QUIT)
			break;
		SDL_Rect R;
		R.x = 0;
		R.y = 0;
		R.w = 700;
		R.h = 800;
		SDL_FillRect(Screen, &R, 0x00000);
		printf("WOOT?\n");
		W_DrawToSurface(W, Screen);  
		printf("WOOT2\n");
		SDL_Flip(Screen);
		SDL_Delay(50);
	}
	return 0;
}
